package com.bear.fastrepair.entity

import android.os.Parcelable
import kotlinx.parcelize.Parcelize

data class EmployeeOrderInfoPage(
    val code: Int,
    val `data`: EmployeeOrderPage,
    val msg: String
)

data class EmployeeOrderPage(
    val pageTotal: Int,
    val records: List<Record>?,
    val total: Int
)

@Parcelize
data class Record(
    val addressDetail: String,
    val clientName: String,
    val clientTel: String,
    val description: String,
    val id: String,
    val locationAddress: String,
    val locationLatitude: String,
    val locationLongitude: String,
    val orderNo: String,
    val serviceOrderStatus: Int,
    val serviceOrderStatusText: String,
    var newOrNot: Boolean = false
): Parcelable

data class EmployeeOrderInfoPagePosition(
    val pageData: EmployeeOrderInfoPage,
    val currentPage: Int,
    val loadMore: Boolean,
    var loading: Boolean = false
)

interface ItemTypeOrder {
    val itemType: Int
}

data class RecordItem(val record: Record, override val itemType: Int = 0) : ItemTypeOrder
data class FooterItem(override val itemType: Int = 1) : ItemTypeOrder